import Cookies from 'js-cookie'
// import Cookies from 'vue-cookie'

export function getToken () {
  return {
    token: Cookies.get('token'),
    userId: Cookies.get('userId')
  }
}

export function setToken (token, userId) {
  if (token) Cookies.set('token', token)
  if (userId) Cookies.set('userId', userId)
}

export function removeToken () {
  Cookies.remove('token')
  Cookies.remove('userId')
}
